<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/11/1 0001
 * Time: 下午 4:42
 */
namespace app\api\controller;

use think\Request;

class Businessarea extends Base
{
    public function getBusinessArea(Request $request)
    {
        $param = $request->param();
        if (empty($param['appId'])) {
            return show(config('status.error_code'), '缺少参数', '缺少参数');
        }
        $Businessarea = \app\admin\model\Businessarea::where('appId', $param['appId'])->find();

        if ($Businessarea) {
            return show(config('status.success'), 'ok', $Businessarea);
        } else {
            return show(config('status.error_code'), 'error', null);
        }
    }
}